<!DOCTYPE html>
<html lang="zh-CN" xmlns:v-on="http://www.w3.org/1999/xhtml">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <meta name="viewport"
          content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0,user-scalable=no,minimal-ui">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="icon" href="../img/asset-favico.ico">
    <title>评估问卷</title>
    <script src="../plugins/healthmobile.js"></script>
    <script>
        var id = getUrlParam("id");
    </script>

    <link rel="stylesheet" href="../css/page-health-riskQuestion.css"/>
</head>

<body data-spy="scroll" data-target="#myNavbar" data-offset="150">
<div id="app" class="app">
    <!-- 页面头部 -->
    <div class="top-header">
        <span class="f-left"><i class="icon-back"></i>返回</span>
        <span class="center">传智健康</span>
        <span class="f-right"><i class="icon-more"></i></span>
    </div>
    <!-- 页面内容 -->
    <div class="contentBox">
        <div class="question">
            <div class="q-tit">
                <p class="type-num"><span><i class="cur-num">1</i>/<i class="total-num">19</i>[<i
                        class="type">单选</i>]</span></p>
                <p class="tit">食欲不振</p>
            </div>
            <div class="q-choose">
                <div class="choose-items">
                    <div class="input-row radio left">
                        <input id="item1" type="radio" name="item" value="1" checked>
                        <label for="item1"></label>
                        <span>从无</span>
                    </div>
                    <div class="input-row radio left">
                        <input id="item2" type="radio" name="item" value="2">
                        <label for="item2"></label>
                        <span>轻度</span>
                    </div>
                    <div class="input-row radio left">
                        <input id="item3" type="radio" name="item" value="3" checked>
                        <label for="item3"></label>
                        <span>中度</span>
                    </div>
                    <div class="input-row radio left">
                        <input id="item4" type="radio" name="item" value="4" checked>
                        <label for="item4"></label>
                        <span>偏重</span>
                    </div>
                    <div class="input-row radio left">
                        <input id="item5" type="radio" name="item" value="5" checked>
                        <label for="item5"></label>
                        <span>严重</span>
                    </div>
                </div>
                <div class="tool-btn">
                    <a class="btn next-btn" @click="find()">下一题</a>
                    <a class="btn cancle-btn">取消</a>
                </div>
            </div>
        </div>
    </div>
</div>

<script src="../js/vue.js"></script>
<script src="../js/jquery-3.3.1.min.js"></script>
<script src="../js/axios-0.18.0.js"></script>


<script>
    var vue = new Vue({
        el: '#app',
        methods: {
            find() {
                let value=$("input:checked").val();
                let id=$(".cur-num").html();
                axios.post("/xingliQuestion/find.do?id="+id+"&value="+value).then((res) => {
                    if(res.data.data.id==67){
                        $(".tit").html(res.data.data.question);
                        $(".q-choose").hide();
                    }else{
                        $(".tit").html(res.data.data.question);
                        $(".cur-num").html(res.data.data.id);
                        $("#item1").prop("checked",true);
                    }
                })
            }
        },
    });
</script>


<!--<script src="health-index.js"></script>-->


</body>


